package inf.coach.mobile;


import android.app.AlertDialog;
import android.app.AlertDialog.Builder;
import android.content.Context;
import android.content.DialogInterface;
import android.content.Intent;
import android.os.Bundle;

public class message {

	public static void show (Context context,final String title, String message){
		Context com=context;
		new AlertDialog.Builder(context)
		 .setTitle(title)
		 .setMessage(message)
		 .setPositiveButton("OK", new DialogInterface.OnClickListener() {
	          
	            public void onClick(DialogInterface dialog, int which) {
	            	
	            	dialog.dismiss();

	            }
	        })
		 .show();
	}
	
	/* public void dialoggoback(Context context) {
		 	
	        AlertDialog.Builder builder = new Builder(context); 
	        builder.setMessage("Möchten Sie nach Login-Seite gehen ?"); 
	        builder.setTitle("Information"); 
	        builder.setPositiveButton("ok", 
	                new android.content.DialogInterface.OnClickListener() { 
	                    @Override 
	                    public void onClick(DialogInterface dialog, int which) { 
	                        dialog.dismiss(); 
	                        context.finish(); 
	                    }

	                }); 
	        builder.setNegativeButton("abbrechen", 
	                new android.content.DialogInterface.OnClickListener() { 
	                    @Override 
	                    public void onClick(DialogInterface dialog, int which) { 
	                        dialog.dismiss(); 
	                    } 
	                }); 
	        builder.create().show(); */
	    
	
	/*public static void msg (final Context context,final String  title, String message, Class c, final long userid, final long osmid){
		
		new AlertDialog.Builder(context)
		.setTitle(title).setMessage(message)
		.setPositiveButton("ok",new DialogInterface.OnClickListener() {
			
			@Override
			public void onClick(DialogInterface dialog, int which) {
				// TODO Auto-generated method stub
				Intent intent = new Intent();
				Bundle bundle = new Bundle();

				bundle.putLong("osmid", osmid);
				bundle.putLong("userid", userid);

				intent.setClass(context, Entranceanno.class);
				intent.putExtras(bundle);
				startActivity(intent);

				
			}
		})
		.setNegativeButton("cancel", new DialogInterface.OnClickListener() {
			
			@Override
			public void onClick(DialogInterface dialog, int which) {
				// TODO Auto-generated method stub
				
			}
		})
		.show();
	}*/
}
